import request from '@/utils/request'

/**
 * 地震预警产出列表
 * null
 */
export const earthquakeList = (params) => {
  return request({
    url: '/earthquake/list',
    method: 'GET',
    params,
  })
}

/**
 * 地震触发列表
 * null
 */
export const projectQuickReportList = (params) => {
  return request({
    url: '/projectQuickReport/list',
    method: 'GET',
    params,
  })
}

/**
 * 区域触发事件 区域触发事件
 * null
 */
export const areaEvent = (params) => {
  return request({
    url: '/event/areaEvent',
    method: 'GET',
    params,
  })
}

/**
 * 测点触发事件 测点触发事件
 * null
 */
export const pointEvent = (params) => {
  return request({
    url: '/event/pointEvent',
    method: 'GET',
    params,
  })
}

/**
 * 报告产出文件下载
 * null
 */
export const downloadGenerateById = (generateId: string, docType = 'pdf') => {
  return request({
    url: `/produce/downloadGenerateById/${generateId}/${docType}`,
    method: 'GET',
    responseType: 'blob',
  })
}
